package com.junchenrobot.mes.listener.impl;

import com.junchenrobot.mes.core.TaskScheduled;
import com.junchenrobot.mes.listener.InputTaskListener;
import com.junchenrobot.mes.listener.moudle.InputTaskEvent;

public class DefaultInputTaskImpl implements InputTaskListener {

    private final TaskScheduled taskScheduled;

    public DefaultInputTaskImpl(TaskScheduled taskScheduled) {
        this.taskScheduled = taskScheduled;
    }

    /**
     * 装载任务推送
     *
     * @param inputTaskEvent 装载任务事件
     */
    @Override
    public void pushInputTask(InputTaskEvent inputTaskEvent) {
        taskScheduled.createWinderTask(inputTaskEvent.getWorkList());
    }

}
